<template>
	<view class="tick_main">
		<view class="admissionTicketCard-box" v-for="(item, index) in dataList" :key="index" @click="opDetail(item)">
			<view class="admissionTicketCard">
				<view class="admissionTicketCard-img"><image :src="item.img ? item.img.split(',')[0] : ''"></image></view>
				<view class="admissionTicketCard-details">
					<view class="name u-line-1">{{ item.name }}</view>
					<view class="title u-line-2">{{ item.title || '' }}</view>
					<view class="admissionTicketCard-details-price">
						<view class="details-price-left">
							<text class="price-left-icon">¥</text>
							<text class="price-left-price">{{ item.amount }}</text>
							<text class="price-left-icon">起</text>
						</view>
						<text class="details-price-salesVolume" v-if="vuex_config.sales_volume == 1 && item.order_num > 0">已售{{ item.order_num || 0 }}份</text>
						<view class="apoint">立即预订</view>
					</view>
				</view>
			</view>
		</view>
	</view>
</template>

<script>
export default {
	props:{
		dataList:{
			type:Array,
			default:[]
		}
	},
	components: {},
	data() {
		return {};
	},
	mounted() {},

	methods: {
		opDetail (item) {
			
			this.$toProd({ ...item, prodType: 9 });
		}
	}
};
</script>

<style scoped lang="scss">
.tick_main {
	background-color: #fff;
}
.admissionTicketCard-box {
	padding: 4rpx 30rpx 30rpx;
}
.admissionTicketCard {
	width: 690rpx;
	height: 220rpx;
	box-shadow: 0px 4px 11px 2px rgba(153, 152, 152, 0.15);
	border-radius: 8px;
	padding: 20rpx;
	display: flex;
}
.admissionTicketCard-img {
	margin-right: 18rpx;
	width: 220rpx;
	height: 180rpx;
	border-radius: 10px;
	overflow: hidden;
	background-color: #f4f4f4;
}
.admissionTicketCard-details {
	flex: 1;
	overflow: hidden;
}
.name {
	color: #333;
	font-weight: bold;
	font-size: 28rpx;
}
.title {
	font-size: 24rpx;
	color: #666;
	line-height: 34rpx;
	height: 68rpx;
	margin-top: 12rpx;
}
.admissionTicketCard-details-price {
	display: flex;
	align-items: center;
	justify-content: space-between;
	margin-top: 10rpx;
	.details-price-left {
		flex: 1;
		overflow: hidden;
		display: flex;
		align-items: center;
		.price-left-icon {
			font-size: 24rpx;
			color: #ff1f00;
			font-weight: bold;
			font-family: PingFang SC;
		}
		.price-left-price {
			font-size: 36rpx;
			color: #ff1f00;
			margin: 0 4rpx;
			font-weight: bold;
			font-family: PingFang SC;
		}
	}
	.details-price-salesVolume {
		flex: 1;
		overflow: hidden;
		font-size: 24rpx;
		color: #666;
	}
	.apoint {
		background: #f34d4e;
		line-height: 46rpx;
		border-radius: 8rpx;
		padding: 0 10rpx;
		font-size: 22rpx;
		color: #fff;
	}
}
</style>
